Choose the right dataset type
Every dataset has a type, chosen when you create it. The type decides how you label the images and what the model will answer on the line, so start from the question the inspection has to answer.
| Type | The question it answers | You label each image by | Example |
|---|---|---|---|
| Classification | What is this product? Is it good? | Choosing one tag | A jar is ok, stained or broken |
| Anomaly detection | Does this product look different from a good one? | Marking it normal or anomaly, and painting the defect | Scratches on a surface, where every defect looks different |
| Object detection | Where are the objects, and how many are there? | Drawing a box around each object | Counting the biscuits in a pack, finding a missing cap |
| Object detection, oriented boxes | The same, for objects that lie at an angle | Drawing a rotated box around each object | Bottles lying on a conveyor in any direction |
| Image segmentation | Exactly which area is affected, and how big is it? | Painting the shape of each defect | Measuring a crack or the area of a stain |
| Text recognition | What does the printed text say? | Drawing a box around each text and typing it | Reading a date or a lot code |
Oriented boxes are an option of object detection: after choosing «Object detection», the platform asks whether the boxes are normal or oriented.
How to decide
- One verdict per image, and you can name every case (ok, stained, broken): classification. It is the quickest to label.
- One verdict per image, but defects are rare or never look the same: anomaly detection. The model learns what a good product looks like and flags what differs, so it needs mostly good images.
- Several things in one image, or you need to know where they are: object detection. Use oriented boxes when the objects are not aligned with the image and a straight box would take in too much background.
- The size or the shape of the defect matters, not only whether there is one: image segmentation. It takes the longest to label.
- You need to read characters: text recognition. To read text without training a model, the OCR node of the flows may be enough.
When in doubt, start simple. A classification dataset labeled in an afternoon tells you quickly whether the camera and the light show the defect well enough.
Changing your mind
The type of a dataset cannot be edited, but some types can be converted into a new dataset without labeling again, from «More options» → «Convert»: object detection and image segmentation into classification, oriented boxes into normal boxes or classification, anomaly detection into classification, and segmentation into object detection. You can also copy the images of a dataset into a new one of another type and label them there.